const state = {
  activeRoom: '',
  activeVM: '',
}

const mutations = {
  ACTIVE_ROOM: (state, rid) => {
    state.activeRoom = rid
  },
  ACTIVE_VM: (state, mid) => {
    state.activeVM = mid
  },
}

const actions = {
  activeRoom({ commit }, data) {
    commit('ACTIVE_ROOM', data)
  },
  activeVM({ commit }, data) {
    commit('ACTIVE_VM', data)
  },
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
